package cn.itcast.nems.order.dao.mapper;

import cn.itcast.nems.order.dao.entity.OrderRefundReverse;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Collection;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 退费单-回冲 Mapper 接口
 * </p>
 *
 * @author liyong
 * @since 2023-09-14
 */
@Mapper
public interface OrderRefundReverseMapper extends BaseMapper<OrderRefundReverse> {

    /**
     * 查询回冲信息
     *
     * @param orderRefundIds 退费单ID
     * @return key：列名order_refund_id,amount value：对应的列值
     */
    @MapKey("order_refund_id")
    List<Map<String, Object>> selectOrderRefundReverses(@Param("orderRefundIds") Collection<String> orderRefundIds);


    List<Map<String, Object>> orderRefundBack(String orderRefundId);
}
